<?php
error_reporting(0);
$isadmin=1; 
include_once '../comm/config.php';
include_once 'include/page.class.php';
include_once '../comm/checkpostandget.php';
include_once 'check.php';
$page = !($_GET['page'])?'1':intval($_GET['page']);
$pagesize=20;
$page2=($page-1)*$pagesize;
	
$sql="select * from ".$BIAOTOU."nav order by sort desc limit $page2,$pagesize";
$rs = mysql_query($sql);

$hide=array(0=>'显示',1=>'隐藏');
$target=array(0=>'进入',1=>'弹出');
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>管理中心</title>
<link href="css/style.css" rel="stylesheet" type="text/css">
</head>

<body topmargin="5" leftmargin="0">
<table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="282" valign="top"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td>
          <table cellspacing="0" width="100%" height="207" style="border:1px  solid #DCEAF7;">
            <tr>
              <td height="30" bgcolor="E9F2FB" class="bigtext"><strong>&nbsp;<img src="images/arrow.gif" width="16" height="22" align="absmiddle" /> 站点导航管理 [ <a href="addnav.php" class="link3">新增站点导航</a> ] </strong></td>
              <td width="188" align="right" bgcolor="E9F2FB" class="bigtext"></td>
            </tr>
            <tr>
              <td colspan="2" valign="top"><table width="100%" height="300" border="0" cellpadding="0" cellspacing="0">
                <tr>
                  <td valign="top"><table width="100%" border=1 cellpadding=0 cellspacing=0
style="border-collapse: collapse" bordercolor="#dddddd">
                  
                    <tr>
                      <td width="5%"  height="30" align="center" bgcolor="#F2F2F2" class="bigtext"><strong>&nbsp;排序</strong></td>
					  <td width="8%" align="center"  bgcolor="#F2F2F2" class="bigtext"><strong>&nbsp;名称</strong></td>
                      <td width="" align="center"  bgcolor="#F2F2F2" class="bigtext"><strong>&nbsp;链接</strong></td>
                      <td width="5%"  align="center" bgcolor="#F2F2F2" class="bigtext"><strong>&nbsp;状态</strong></td>
                      <td width="7%"  align="center" bgcolor="#F2F2F2" class="bigtext"><strong>&nbsp;导航方式</strong></td>
                      <td width="11%"  align="center" bgcolor="#F2F2F2" class="bigtext"><strong>&nbsp;tag标记</strong></td>
                      <td width="10%"  align="center" bgcolor="#F2F2F2" class="bigtext"><strong>&nbsp;操作</strong></td>
                    </tr>
					<?php
					while ($row = mysql_fetch_array($rs))
					{
						echo "<tr>";
                      	echo "<td align=center height=30 class=bigtext>".$row["sort"]."</td>";
						echo "<td align=center class=bigtext>".$row["name"]."</td>";
						echo "<td align=center class=bigtext>".$row["link"]."</td>";
						echo "<td align=center class=bigtext>".$hide[$row["hide"]]."</td>";
						echo "<td align=center class=bigtext>".$target[$row["target"]]."</td>";
						echo "<td align=center class=bigtext>".$row["tag"]."</td>";
						echo "<td align=center class=bigtext><a href=addnav.php?id=".$row["id"]." class=link4>修改</a> <a onclick=\"return confirm('您确定要删除吗?')\" href=delnav.php?id=".$row["id"]." class=link4>删除</a> </td>";
						echo "</tr>";
					}
					?>
                  </table>
				  <div class="yahoo2" style=" margin-top:30px;"><?php 
				pageft($total,$pagesize,1,1,0,10,"adlist.php?keyword=1");
				echo $pagenav;?></div></td>
                </tr>
              </table></td>
            </tr>
          </table></td>
        </tr>
      
    </table></td>
  </tr>
</table>
</body>
</html>
<?php mysql_close();?>
